<!DOCTYPE html>
<html lang="zh">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>画一个冰墩墩给你看</title>
  </head>
  <body>
    <style id="demo2"></style>
    <div id="demo"></div>
    <div id="buttons">
      <button id="btnPause">暂停</button>
      <button id="btnPlay">播放</button>
      <button id="btnSlow">慢速</button>
      <button id="btnNormal">中速</button>
      <button id="btnFast">快速</button>
    </div>
    <style>
      * {
        box-sizing: border-box;
      }
      *::before,
      *::after {
        box-sizing: border-box;
      }
      #buttons {
        position: fixed;
        right: 0;
        top: 0;
        z-index: 10;
        display: flex;
        flex-direction: column;
        margin-top: 10px;
        margin-right: 10px;
      }
      #buttons > button {
        margin-bottom: 10px;
        padding: 4px 8px;
      }
      #demo2 {
        display: none;
      }
      #demo {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 40vh;
        overflow-y: auto;
      }
      #demo::-webkit-scrollbar {
        display: none;
      }
      #html {
        width: 400px;
        height: 500px;
        top: 50px;
        margin: 0 auto;
        position: relative;
      }
      .nose:hover {
        animation: wave 300ms infinite linear;
      }
      @keyframes wave {
        0% {
          transform: rotate(0deg);
        }
        33% {
          transform: rotate(5deg);
        }
        66% {
          transform: rotate(-5deg);
        }
        100% {
          transform: rotate(0deg);
        }
      }
      @media (max-width: 500px) {
        #html {
          position: fixed;
          top: 180px;
          left: 0;
          width: 100%;
          height: 60vh;
        }
      }
    </style>
    <div id="html">
      <div class="ear left"></div>
      <div class="ear right"></div>
      <div class="arm left"></div>
      <div class="arm right">
        <div class="heart">
          <div class="one"></div>
          <div class="another"></div>
        </div>
      </div>
      <div class="leg left"></div>
      <div class="leg right"></div>
      <div class="skin">
        <div class="line">
          <div class="line one"></div>
          <div class="line two"></div>
          <div class="line three"></div>
          <div class="line four"></div>
          <div class="line five"></div>
        </div>

        <div class="eye left">
          <div class="white-eye">
            <div class="grey-eye"></div>
          </div>
        </div>
        <div class="eye right">
          <div class="white-eye">
            <div class="grey-eye"></div>
          </div>
        </div>
        <div class="nose"></div>
        <div class="mouth"></div>
        <div class="mouth-down"></div>
      </div>
    </div>
    <script src="test.js"></script>
  </body>
</html>
